<script setup>
import {useCounterStore} from '../stores/counter'
import {  storeToRefs} from 'pinia'
const store=useCounterStore();
//const { count, doubleCount } = store
const { count, doubleCount } = storeToRefs(store)
</script>

<template>
  <main>
    Home页
{{count}}----{{doubleCount}}
<button @click="store.increment()">单击+1</button>
  </main>
</template>
